//引入xylj.js
import request from './xylj'



//封装登录接口
export function LoginApi(data) {
    return request({
        url: '/login',
        method: 'POST',
        data
    })
}

//封装权限列表接口
export function Power() {
    return request({
        url: '/menus',
        method: 'GET',
    })
}

//请求用户列表数据
export function Listuser(params) {
    return request({
        url: '/users',
        method: 'GET',
        params
    })
}

//分装添加用户
export function addUser(data) {
    return request({
        url: '/users',
        method: 'POST',
        data
    })

}

//封装删除
export function delUser(data) {
    return request({
        url: '/users/' + data,
        method: 'Delete',
        data
    })
}

//封装编辑用户
export function eDit(data) {
    return request({
        url: '/users/' + data,
        method: 'PUT',
        data
    })
}